package com.hp.easyBuy.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
import java.util.List;

@TableName(value = "t_order")
public class TOrder {
  @TableId(value = "ORDERID",type = IdType.AUTO)
  private long orderid;
    private long userid;
  private long addressid;
  @JsonFormat(pattern = "yyyy-MM-dd")
  @DateTimeFormat(pattern="yyyy-MM-dd")
  @TableField(value = "ORDERTIME")
  private Date ordertime;
  private long orderstatus;
  private double totalprice;
  private String remarks;

  private List<TOrderDetailsDTO> list;//查询订单详情
  private TAddress address;//一对一查询地址详细信息





  public List<TOrderDetailsDTO> getList() {
    return list;
  }

  public void setList(List<TOrderDetailsDTO> list) {
    this.list = list;
  }

  public TAddress getAddress() {
    return address;
  }

  public void setAddress(TAddress address) {
    this.address = address;
  }

  public long getOrderid() {
    return orderid;
  }

  public void setOrderid(long orderid) {
    this.orderid = orderid;
  }


  public long getUserid() {
    return userid;
  }

  public void setUserid(long userid) {
    this.userid = userid;
  }


  public long getAddressid() {
    return addressid;
  }

  public void setAddressid(long addressid) {
    this.addressid = addressid;
  }


  public Date getOrdertime() {
    return ordertime;
  }

  public void setOrdertime(Date ordertime) {
    this.ordertime = ordertime;
  }


  public long getOrderstatus() {
    return orderstatus;
  }

  public void setOrderstatus(long orderstatus) {
    this.orderstatus = orderstatus;
  }


  public double getTotalprice() {
    return totalprice;
  }

  public void setTotalprice(double totalprice) {
    this.totalprice = totalprice;
  }


  public String getRemarks() {
    return remarks;
  }

  public void setRemarks(String remarks) {
    this.remarks = remarks;
  }

}
